#ifndef _TRACELOG_H_
#define _TRACELOG_H_

#include <assert.h>
#include "BaseType.h"

/*****************************************************************************
 *
 *  Debug Functions
 *
 ****************************************************************************/
extern ULONG GlobalLogLevel;
extern ULONG GlobalLogComponents;

STATUS LogOpen( char* LogFileName );
void LogClose();
void LogMsg( ULONG _Comp,ULONG  _Level, const char* fmt, ... );
void LogDumpData( ULONG _Comp, ULONG _Level, char* StrName, PUCHAR Data, ULONG Size );

#define FuncEntry \
{ \
        LogMsg( COMP_ALL, DBG_FUNCTION, "==> " __FUNCTION__ "\n" ); \
}
#define FuncExit \
{ \
        LogMsg( COMP_ALL, DBG_FUNCTION, "<== " __FUNCTION__ "\n" ); \
}

//#define ASSERT( _x_ )  do{ if ( 0 == _x_ ) __debug_break();}while(0);
#define ASSERT( _x_ ) assert( _x_ )

#endif // _TRACELOG_H_
